define(["dojo/_base/declare","dijit/_WidgetBase", "dijit/_TemplatedMixin", 
        "dojo/text!./testWidget/templates/testWidget.html",       
        "dojo", "dojo/_base/xhr", "dojo/on", "dojo/dom", "dojo/dom-class", "dojo/parser",
		"dojo/query", "dojo/dom-attr", "dojo/dom-style", "dojo/dom-construct", "dojo/keys",
		"dojox/widget/Standby", "dojo/fx/Toggler", "dojo/fx", "dojox/fx/text", "dojox/html", "dojox/validate", "dojo/_base/connect", 
		"dijit/registry", "dojo/_base/array", "dojo/_base/lang", "dijit/layout/ContentPane",
		"dojox/html/_base", 
		"dijit/MenuBar", "dijit/PopupMenuBarItem", "dijit/form/ToggleButton",
		"dijit/form/ComboButton", "dijit/Menu", "dijit/MenuItem", "dijit/form/DropDownButton",
		"dijit/TooltipDialog", "dojo/NodeList-traverse", "dojo/NodeList-manipulate",
		"dojo/io/script",
		"dojox/validate/us", "dojox/validate/web", "dijit/form/CheckBox", "dijit/form/Textarea",
		"dijit/form/Select", "dijit/form/TextBox", "dijit/form/ValidationTextBox",
		"dijit/form/DateTextBox", "dijit/form/TimeTextBox", "dijit/form/Button",
		"dijit/form/RadioButton", "dijit/form/Form", "dijit/form/DateTextBox",
		"dojox/form/BusyButton", "dojox/form/CheckedMultiSelect"],
    function(declare, WidgetBase, TemplatedMixin, template, dojo, xhr, on, dom, domClass, parser, query, domAttr, domStyle, construct, keys,
			Standby, Toggler, fx, text, html, validate, connect, registry, array, lang, ContentPane){		
        return declare([WidgetBase, TemplatedMixin], {
        	urls: [],
        	containerId: "",
            templateString: template,
            baseClass: "testWidget",
        	postCreate: function(){
        		var domNode = this.domNode;
        		this.inherited(arguments);
        		console.log(this.domNode);
    			console.log(this.templateString);
    			console.log(this.pageNumberDivNode);
        		html.set(dom.byId(this.containerId), this.templateString);
        		 array.forEach(this.urls, function(url, index){
        			var newImgDomNode = construct.create("url");
        			console.log(this.imageContainerNode);
        			
        			construct.place(newImgDomNode, this.imageContainerNode);
 		        }); 
        	}
        });
});



